import {defineConfig} from 'vite'
import vue from '@vitejs/plugin-vue'
import ElementPlus from 'unplugin-element-plus/vite'

// https://vitejs.dev/config/
export default defineConfig({
  base: '/doms_specialist_settings/',
  plugins: [
    vue(),
    ElementPlus({}),
    /*
    viteCompression({
      // threshold: 1024000 // 对大于 1mb 的文件进行压缩
    })
    */
  ],
  // 配置项目别名
  resolve: {
    alias: {
      '@': '/src',
    },
  },
  css: {
    preprocessorOptions: {
      scss: {
        additionalData: '@use "@/style/reset.scss";' +
          '@import "@/style/var.scss";'
      }
    }
  },
  build: {},
  envDir: 'env'
})
